package com.pw.lit.service.impl;


import com.pw.lit.bean.Category;
import com.pw.lit.bean.CategoryExample;
import com.pw.lit.mapper.CategoryMapper;
import com.pw.lit.service.CategoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;


@Service("categoryService")
public class CategoryServiceImpl implements CategoryService {

    @Autowired
    private CategoryMapper categoryMapper;

    @Override
    public int countByExample(CategoryExample example) {
        return categoryMapper.countByExample(example);
    }

    @Override
    public int deleteByExample(CategoryExample example) {
        return categoryMapper.deleteByExample(example);
    }

    @Override
    public int deleteByPrimaryKey(Integer cid) {
        return categoryMapper.deleteByPrimaryKey(cid);
    }

    @Override
    public int insert(Category record) {
        return categoryMapper.insert(record);
    }

    @Override
    public int insertSelective(Category record) {
        return categoryMapper.insertSelective(record);
    }

    @Override
    public List<Category> selectByExample(CategoryExample example) {
        return categoryMapper.selectByExample(example);
    }

    @Override
    public Category selectByPrimaryKey(Integer cid) {
        return categoryMapper.selectByPrimaryKey(cid);
    }

    @Override
    public int updateByExampleSelective(Category record, CategoryExample example) {
        return categoryMapper.updateByExampleSelective(record,example);
    }

    @Override
    public int updateByExample(Category record, CategoryExample example) {
        return categoryMapper.updateByExampleSelective(record,example);
    }

    @Override
    public int updateByPrimaryKeySelective(Category record) {
        return categoryMapper.updateByPrimaryKeySelective(record);
    }

    @Override
    public int updateByPrimaryKey(Category record) {
        return categoryMapper.updateByPrimaryKey(record);
    }
}